* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

li {
    list-style: none;
}

a {
    text-decoration: none;
}

img {
    width: 100%;
    vertical-align: middle;
}
.pic:hover .text {
    animation: textChange 0.5s forwards;
}
.pic:hover .bgcolor {
    animation: bgChange 0.2s forwards;
}

.box {
    width: 1110px;
    height: 247px;
    margin: 20px auto;
}

.box li {
    position: relative;
    float: left;
    width: 350px;
    height: 247px;
    margin-right: 30px;
    overflow: hidden;
}


.box li:last-child {
    margin-right: 0;
}

.pic .text {
    position: absolute;
    top: 135px;
    width: 350px;
    color: white;
    margin-left: 30px;
    z-index: 3;
}

.pic .text:hover {
    animation: bgChange 0.2s forwards;
    animation: textChange 0.5s forwards;
}

@keyframes textChange {
    from {
        position: absolute;
        top: 135px;
    }
    to {
        position: absolute;
        top: 60px;
    }
}
@keyframes bgChange {
    from {
        background-image: linear-gradient(transparent,
        transparent);
    }
    to {
        background-image: linear-gradient(transparent,
          rgba(0, 0, 0, 0.5));
    }
}

.pic .text span {
    font-size: 20px;
}
.pic .text div {
    margin-top: 50px;
}
.pic .text div {
    margin-top: 50px;
}
.box li:nth-child(2) .text p {
    margin-top: 25px;
}
.box li:nth-child(2) .text p {
    margin-top: 30px;
}
.bgcolor {
    width: 350px;
    height: 247px;
    position: absolute;
    top: 0;
}